package com.zyh.date;

import java.util.Date;

public class DateDemo1 {
    public static void main(String[] args) {
        Date date1 = new Date(353454500000000L);
        Date date2 = new Date(6534545000000000L);
        long time1 = date1.getTime();
        long time2 = date2.getTime();
        long day = Math.abs(time1 - time2);
        System.out.println("day = " + day);
        System.out.println("date1 = " + date1);
        System.out.println("date2 = " + date2);
        day=day/1000/60/60/24;
        System.out.println("day = " + day);
    }
}
